package com.cea.papyrus.core.treeeditpart;

import org.eclipse.gef.Request;

import com.cea.papyrus.core.actions.OpenDiagramAction;

/**
 * Selection tool specialized for the Outline
 */
public class TreeSelectionTool extends org.eclipse.gef.tools.SelectionTool {

	/**
	 * Creates a new TreeSelectionTool.
	 */
	public TreeSelectionTool()  {
		super();
	}
	
	/* (non-Javadoc)
	 * @see org.eclipse.gef.tools.AbstractTool#handleDoubleClick(int)
	 */
	@Override
	protected boolean handleDoubleClick(int button) {
		if(getTargetEditPart()!=null) {
			getTargetEditPart().performRequest(new Request(OpenDiagramAction.OPEN_DIAGRAM_ACTION_REQUEST));
		}
		return true;
	}
}
